include Makefile.com

CFLAGS=-Wall -Iinclude -nostdlib -nostartfiles -ffreestanding -std=gnu99 -fno-stack-protector -nostdlib -nostdinc -fno-builtin -nodefaultlibs
LDFLAGS=-Tarch/x86/link.ld
ASFLAGS=-felf

OBJS=arch/x86/boot.o arch/x86/dt.o arch/x86/clock.o arch/x86/timer.o arch/x86/io.o arch/x86/arch.o arch/x86/kvideo.o arch/x86/kkeyb.o arch/x86/calls.o
KERNEL=arch/x86/kernel

TCC=gcc
TAS=as
TLD=ld
TASM=nasm


SOURCES=$(OBJS)  trace.o     drivers/video/vesa/vesa.o drivers/bus/pci/pci.o drivers/net/rs232/rs232.o shell/shell.o ../app/porkgui/render.o ../app/porkgui/pork_gui.o ../app/porkgui/env.o $(COM_O)

all: $(SOURCES) link
.s.o:
	$(ASM) $(ASFLAGS) $<
link:
	$(LD) $(LDFLAGS) -o arch/x86/kernel $(SOURCES)

clean:
	rm $(SOURCES)
